import 'package:casdon/modules/login/domain/validators/input_validator.dart';

class PhoneValidator implements InputValidator {
  @override
  bool isValude(String input) {
    final phoneReg = RegExp(r'^1[3-9]\d{9}$');
    return phoneReg.hasMatch(input);
  }
    @override
  String? validateWithMessage(String input) {
    return isValude(input) ? null : '手机号格式不正确';
  }
}


